home *** CD-ROM | disk | FTP | other *** search
/ Night Owl 6 / Night Owl's Shareware - PDSI-006 - Night Owl Corp (1990).iso / 025a / rrdemo.zip / DEMO.BAT < prev    next >
DOS Batch File  |  1991-12-02  |  6KB  |  216 lines

  1. echo off
  2. cls
  3. REM Installation program for R&R Report Writer Demonstration
  4. REM (C) 1991 Copyright Show & Tell, Inc.  
  5. break=on
  6. batchman window 1, 1, 80, 25, 0Fh,-
  7. batchman window 3, 7, 70, 3, 1Fh
  8. batchman window 3, 7, 9, 3, 4Fh
  9. batchman setcursor 4,8
  10. batchman cecho, C   R&R 
  11. batchman setcursor 4, 17
  12. batchman cecho, C Report Writer Demonstration Installation  
  13. batchman setcursor 8, 17
  14. batchman cecho, C This procedure creates a subdirectory named RRDEMO on 
  15. batchman setcursor 9, 17
  16. batchman cecho, C your hard disk and copies the demonstration files     
  17. batchman setcursor 10, 17
  18. batchman cecho, C into that subdirectory.
  19. batchman setcursor 12, 17
  20. batchman cecho, C The demo requires approximately 600 KB of disk space.
  21. batchman setcursor 16, 17
  22. batchman cecho, C Would you like to install the demonstration? (Y or N) [ ]
  23. batchman setcursor 24, 20
  24. batchman cecho, C Press [CONTROL-BREAK] to Exit Installation
  25. batchman setcursor 16, 72
  26. batchman getkey 'yn'
  27. IF ERRORLEVEL 2 goto NOINST
  28. IF ERRORLEVEL 1 goto DRIVE
  29. goto end
  30.  
  31. :NOINST
  32. batchman cecho, C N
  33. goto end
  34.  
  35. :drive
  36. batchman cecho, C Y
  37. batchman setcursor 18, 16
  38. batchman cecho, C  Which disk drive would you like to copy the demo to? [ ]
  39. batchman setcursor 19, 16
  40. batchman cecho, C             (Please enter a drive C through F)
  41. batchman setcursor 18, 71
  42. batchman getkey 'cdef'
  43. IF ERRORLEVEL 5 goto end
  44. IF ERRORLEVEL 4 goto installf
  45. IF ERRORLEVEL 3 goto installe
  46. IF ERRORLEVEL 2 goto installd
  47. IF ERRORLEVEL 1 goto installc
  48. IF ERRORLEVEL 0 goto end
  49. goto END
  50.  
  51. :old
  52. if x%1==x  goto :error
  53. if x%2==x  goto :error
  54.  
  55. :installc
  56. batchman cecho, C C
  57. batchman driveexist c:
  58. IF ERRORLEVEL 1 goto nextc
  59. IF ERRORLEVEL 0 goto NoDrive
  60. goto nextc
  61. :nextc
  62. free c: 600000      
  63. IF ERRORLEVEL 1 goto NoSpace
  64. batchman window  7, 15, 60, 15, 0Fh
  65. batchman setcursor 13, 17
  66. batchman cecho, C Installing the R&R Report Writer demo on C:\RRDEMO...
  67. batchman setcursor 24, 19
  68. batchman cecho, C Press [CONTROL-BREAK] to cancel installation.
  69. batchman setcursor 25,1
  70. batchman direxist c:\RRDEMO
  71. IF ERRORLEVEL 1 goto copyc
  72. md C:\RRDEMO >nul
  73. goto copyc
  74. :copyc
  75. RRDEMO$ -o C:\RRDEMO >NUL
  76. c:
  77. cd \RRDEMO
  78. goto FINISH
  79. if errorlevel 1 goto :end
  80. goto end
  81.  
  82. :installd
  83. batchman cecho, C D
  84. batchman driveexist d:
  85. IF ERRORLEVEL 1 goto nextd
  86. IF ERRORLEVEL 0 goto NoDrive
  87. goto nextd
  88. :nextd
  89. free d: 600000  
  90. IF ERRORLEVEL 1 goto NoSpace
  91. batchman window  7, 15, 60, 15, 0Fh
  92. batchman setcursor 13, 17
  93. batchman cecho, C Installing the R&R Report Writer demo on D:\RRDEMO...
  94. batchman setcursor 24, 19
  95. batchman cecho, C Press [CONTROL-BREAK] to cancel installation.
  96. batchman setcursor 25,1
  97. batchman direxist d:\RRDEMO
  98. IF ERRORLEVEL 1 goto copyd
  99. md D:\RRDEMO >nul
  100. goto copyd
  101. :copyd
  102. RRDEMO$ -o D:\RRDEMO >NUL
  103. d:
  104. cd \RRDEMO
  105. goto FINISH
  106. if errorlevel 1 goto :end
  107. goto end
  108.  
  109. :installe
  110. batchman cecho, C E
  111. batchman driveexist e:
  112. IF ERRORLEVEL 1 goto nexte
  113. IF ERRORLEVEL 0 goto NoDrive
  114. goto nexte
  115. :nexte
  116. free e: 600000                      
  117. IF ERRORLEVEL 1 goto NoSpace
  118. batchman window  7, 15, 60, 15, 0Fh
  119. batchman setcursor 13, 17
  120. batchman cecho, C Installing the R&R Report Writer demo on E:\RRDEMO
  121. batchman setcursor 24, 19
  122. batchman cecho, C Press [CONTROL-BREAK] to cancel installation.
  123. batchman setcursor 25,1
  124. batchman direxist e:\RRDEMO
  125. IF ERRORLEVEL 1 goto copye
  126. md E:\RRDEMO >nul
  127. goto copye
  128. :copye
  129. RRDEMO$ -o E:\RRDEMO >NUL
  130. e:
  131. cd \RRDEMO
  132. goto FINISH
  133. if errorlevel 1 goto :end
  134. goto end
  135.  
  136.  
  137. :installf
  138. batchman cecho, C F
  139. batchman driveexist f:
  140. IF ERRORLEVEL 1 goto nextf
  141. IF ERRORLEVEL 0 goto NoDrive
  142. goto nextf
  143. :nextf
  144. free f: 600000                      
  145. IF ERRORLEVEL 1 goto NoSpace
  146. batchman window  7, 15, 60, 15, 0Fh
  147. batchman setcursor 13, 17
  148. batchman cecho, C Installing the R&R Report Writer demo on F:\RRDEMO...
  149. batchman setcursor 24, 19
  150. batchman cecho, C Press [CONTROL-BREAK] to cancel installation.
  151. batchman setcursor 25,1
  152. batchman direxist f:\RRDEMO
  153. IF ERRORLEVEL 1 goto copyf
  154. md F:\RRDEMO >nul
  155. goto copyf
  156. :copyf
  157. RRDEMO$ -o F:\RRDEMO >NUL
  158. f:
  159. cd \RRDEMO
  160. goto FINISH
  161. if errorlevel 1 goto :end
  162. goto end
  163.  
  164. :nodrive
  165. batchman window 7, 15, 60, 17, 0Fh
  166. batchman setcursor 14, 22
  167. batchman cecho, C The specified disk drive does not exist!
  168. batchman setcursor 15, 17
  169. batchman cecho, C Please try installing the demo on an existing drive.
  170. batchman setcursor 24, 20
  171. batchman cecho, C       Press [ESCAPE] to return to DOS...                 
  172. batchman setcursor 24, 40
  173. batchman getkey
  174. IF ERRORLEVEL 1 goto end
  175. goto end
  176.  
  177. :noinstall
  178. batchman window 7, 15, 60, 17, 0Fh
  179. batchman setcursor 14, 15
  180. batchman cecho, C The INSTALL program does not work for the specified drive!
  181. batchman setcursor 15, 24
  182. batchman cecho, C Please try installing the demo on Drives C-F.
  183. batchman setcursor 24, 20
  184. batchman cecho, C       Press [ESCAPE] to return to DOS...                      
  185. batchman setcursor 24, 40
  186. batchman getkey
  187. IF ERRORLEVEL 1 goto end
  188. goto end
  189.  
  190. :nospace
  191. batchman window 7, 15, 60, 17, 0Fh
  192. batchman setcursor 14, 25
  193. batchman cecho,   You do not have enough diskspace!
  194. batchman setcursor 15, 24
  195. batchman cecho,   You need 600 KB to install the demo.
  196. batchman setcursor 24, 20
  197. batchman cecho, C       Press [ESCAPE] to return to DOS...            
  198. batchman setcursor 24, 40
  199. batchman getkey
  200. IF ERRORLEVEL 1 goto end
  201. goto end
  202.  
  203. :FINISH
  204. cls
  205. echo  
  206. echo                             Installation completed.                         
  207. echo  
  208. echo        To run the R&R Report Writer demonstration type DEMO then [RETURN].
  209. echo  
  210. goto DONE
  211.  
  212. :END
  213. cls
  214.  
  215. :DONE
  216.